package com.example.drawing;

import androidx.appcompat.app.AppCompatActivity;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;

import com.example.drawing.activity.Activity_1_Basis;
import com.example.drawing.activity.Activity_2_Drawing;
import com.example.drawing.activity.Activity_3_Mobile;
import com.example.drawing.activity.Activity_3_Mobile_2;
import com.example.drawing.view.MyView;

public class MainActivity extends AppCompatActivity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);
//        setContentView(new MyView(this));
        Button basis = (Button) findViewById(R.id.basis);
        Button drawing = (Button) findViewById(R.id.drawing);
        Button press = (Button) findViewById(R.id.press);
        Button longPress = (Button) findViewById(R.id.longPress);

        basis.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                Intent intent = new Intent(MainActivity.this, Activity_1_Basis.class);
                startActivity(intent);
            }
        });

        drawing.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                Intent intent = new Intent(MainActivity.this, Activity_2_Drawing.class);
                startActivity(intent);
            }
        });

        press.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                Intent intent = new Intent(MainActivity.this, Activity_3_Mobile.class);
                startActivity(intent);
            }
        });

        longPress.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                Intent intent = new Intent(MainActivity.this, Activity_3_Mobile_2.class);
                startActivity(intent);
            }
        });

    }
}